package com.gzucm.Scholarship.dto;

import com.gzucm.Scholarship.common.enums.UserType;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.io.Serializable;

@Data
@ApiModel
public class PasswordDTO implements Serializable {

    @ApiModelProperty(value = "学号/工号")
    private String number;

    @ApiModelProperty(value = "旧密码")
    private String oldPassword;

    @NotBlank(message = "缺少新密码")
    @ApiModelProperty(value = "新密码", required = true)
    private String newPassword;

    @ApiModelProperty(value = "身份证号")
    private String idCard;

    @NotNull(message = "用户类型不能为空")
    @ApiModelProperty(value = "用户类型代码", required = true, allowableValues = "0,1")
    private Integer typeCode;

    @ApiModelProperty(value = "用户类型", hidden = true)
    private UserType type;

}
